package com.suoluo.zenadmin.service.crawler.bean;

import java.util.Date;
import java.util.List;




/**
 * 酒店评论的统计信息
 * @author 熊旭
 *
 */
public class HotelReviewBean{
	
	public static enum HotelReviewType{
		Daodao(1),
		Tripadvisor(2),
		Hotels(3),
		Booking(4);
		HotelReviewType(int value){
			this.value = value;
		}
		private final int value;
		
		public int getValue(){
			return value;
		}
	}
	
	/**
	 * 等待抓取
	 */
	public static final int CRAWLER_WAIT = 1;
	
	/**
	 * 抓取中
	 */
	public static final int CRAWLER_DOING = 2;
	
	/**
	 * 抓取成功
	 */
	public static final int CRAWLER_SUCCESS = 3;
	
	/**
	 * 抓取失败
	 */
	public static final int CRAWLER_FAIL = 4;
	
//	t_review_id	int	主键	酒店评论的标识 
	private int reviewId;
	
//	t_hotel_id	int	外键(酒店表)	酒店的标识
	private int hotelId;
//	t_review_type	int	非空	评论的类型
	
//	1.tripadvisor
//	2.hotels
//	3.booking
//	4.agoda
	private HotelReviewType reviewType;
	
	
//	t_review_url	Varchar(512)	非空	每个评论类型的网址，需要通过这个网址去抓取评论信息
	private String reviewUrl;
//	t_review_count	int	nullable	评论总数
//	每个酒店在不同网站下的评论总数
	private int reviewCount;

//	t_review_score	double	nullable	评论的分数
	

//	酒店在不同网站下的评论分数
	
	private double reviewScore;
//	t_review_full_score	double	nullable	评分的满分
//	每个网站的评分满分不同，有十分制，五分制等
	
	private double reviewFullScore;
//	t_review_level	Varchar(8)	nullable	评分的级别
//	酒店在每个网站上的评分统计出的一个级别(优秀，良好等)
	
	private String reviewLevel;
//	t_review_rank	int	nullable	酒店排名，暂时只有道道有这个排名信息
	private int reviewRank;
//	t_crawler_success_count	int	默认值为0	抓取酒店信息成功的次数，每抓取成功一次就增加一次
	
	private int crawlerSuccessCount;
//	t_crawler_fail_count	int	默认值为0	评论信息抓取失败，该值增加1
	
	private int crawlerFailCount;
//	t_crawler_status	int	默认值为0	当前抓取的状态信息
//	0.	没有抓取过
//	1.	抓取成功
//	2.	抓取失败
	
	private int crawlerStatus;
	
	/**
	 * 每次抓取后的时间，当这次抓取失败后，不需要更新该时间
	 */
	private Date crawlerTime;
	
	private List<HotelReviewRecordBean> reviewRecords;

	public int getReviewId() {
		return reviewId;
	}

	public void setReviewId(int reviewId) {
		this.reviewId = reviewId;
	}

	public int getHotelId() {
		return hotelId;
	}

	public void setHotelId(int hotelId) {
		this.hotelId = hotelId;
	}

	public HotelReviewType getReviewType() {
		return reviewType;
	}

	public void setReviewType(HotelReviewType reviewType) {
		this.reviewType = reviewType;
	}

	public String getReviewUrl() {
		return reviewUrl;
	}

	public void setReviewUrl(String reviewUrl) {
		this.reviewUrl = reviewUrl;
	}

	public int getReviewCount() {
		return reviewCount;
	}

	public void setReviewCount(int reviewCount) {
		this.reviewCount = reviewCount;
	}

	public double getReviewScore() {
		return reviewScore;
	}

	public void setReviewScore(double reviewScore) {
		this.reviewScore = reviewScore;
	}

	public double getReviewFullScore() {
		return reviewFullScore;
	}

	public void setReviewFullScore(double reviewFullScore) {
		this.reviewFullScore = reviewFullScore;
	}

	public String getReviewLevel() {
		return reviewLevel;
	}

	public void setReviewLevel(String reviewLevel) {
		this.reviewLevel = reviewLevel;
	}

	public int getReviewRank() {
		return reviewRank;
	}

	public void setReviewRank(int reviewRank) {
		this.reviewRank = reviewRank;
	}

	public int getCrawlerSuccessCount() {
		return crawlerSuccessCount;
	}

	public void setCrawlerSuccessCount(int crawlerSuccessCount) {
		this.crawlerSuccessCount = crawlerSuccessCount;
	}

	public int getCrawlerFailCount() {
		return crawlerFailCount;
	}

	public void setCrawlerFailCount(int crawlerFailCount) {
		this.crawlerFailCount = crawlerFailCount;
	}

	public int getCrawlerStatus() {
		return crawlerStatus;
	}

	public void setCrawlerStatus(int crawlerStatus) {
		this.crawlerStatus = crawlerStatus;
	}

	public List<HotelReviewRecordBean> getReviewRecords() {
		return reviewRecords;
	}

	public void setReviewRecords(List<HotelReviewRecordBean> reviewRecords) {
		this.reviewRecords = reviewRecords;
	}

	public Date getCrawlerTime() {
		return crawlerTime;
	}

	public void setCrawlerTime(Date crawlerTime) {
		this.crawlerTime = crawlerTime;
	}
	
	
}
